#ifndef CLIB_BASE64_H
#define CLIB_BASE64_H

#pragma once

#ifdef __cplusplus
extern "C" {
#endif

#include "clib_type.h"

#define CLIB_BASE64_ENCODE_LEN(len) (((len) + 2) / 3 * 4)

#define CLIB_BASE64_DECODE_LEN(len) ((len) / 4 * 3)

i32_t clib_base64_encode(u08_t *in_buf,i32_t in_len,u08_t *out_buf, i32_t out_max);

i32_t clib_base64_decode(u08_t *in_buf,i32_t in_len,u08_t *out_buf, i32_t out_max);


#ifdef __cplusplus
}
#endif

#endif